﻿@model Dictionary<int, List<Wicresoft.SelfService.DAO.OS>>
@using Wicresoft.SelfService.DAO
@{
    ViewBag.Title = "操作系统维护";
    Layout = "~/Views/Shared/_OSConfigLayout.cshtml";
}

<script type="text/javascript">
        $(document).ready(function(){
            var url="@Url.Action("CreateOS","OSMaintain")";
            $("#rightpart").load(url);
        });
        function getOSInfo(id) {
            var currentID = id;
            var url="@Url.Action("ShowOS", "OSMaintain")";
            url += "?id="+currentID;
            $("#rightpart").load(url);
        }
        function getCreatePage(){
            var url="@Url.Action("CreateOS","OSMaintain")";
            $("#rightpart").load(url);
        }
 </script>

<div class="center">
    <div class="box">
        <div class="main_left">
            <div class="headpart ui-icons">
            </div>
            <div class="left_menu">
                <div class="left_menu_border">
                    <a href="#" id="createUrl" onclick="getCreatePage();">
                       <input type="button" id="CrtBD" value="创建操作系统分类" style=" height:30px; width:193px; font-weight:bold;" />
                    </a>
                </div>
                <hr />
                <div class="left_menu_border">
                    <div class="ui-icons VNavParentI" id="VNavParent1" onclick="VNavParent(this);"> &nbsp;&nbsp;&nbsp;&nbsp; 操作系统列表
                        <ul style="display: none;" id ="SD">
                            @foreach (var item in (List<Wicresoft.SelfService.DAO.OS>)ViewData["OsList"])
                            {
                                <li class="VNavLeaf">
                                    <a href="#" class="ui-icons" id="@(item.ID)" onclick="getOSInfo(@item.ID);getVNavLeaf(1,this);" >
                                        @if (item.OSName.Length < 20){
                                            <span title="@item.OSName">@item.OSName</span>
                                        }
                                        else{
                                            var name1 = item.OSName.Substring(0, 20).ToString() + "...";
                                            <span title="@item.OSName">@name1</span>
                                        }
                                    </a>
                                </li>
                            }
                        </ul>
                    </div>
                </div>
            

            </div>
        </div>
        <div class="main_right" id="rightpart" data-url="">
              
        </div>
    </div>
</div>


